{include file="public/head"}

<body>
<div id="wrapper">

    <div class="gray-bg dashbard-1">
        <div class="wrapper wrapper-content animated fadeInRight">
            <div class="row">
                <div class="col-lg-12">
                    <div class="ibox float-e-margins">
                        <div class="ibox-content">
                            <div class="form-horizontal m-t">
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品名称：</label>
                                    <div class="col-sm-8">
                                        <input id="name" name="name" maxlength="255" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.name}">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品简介：</label>
                                    <div class="col-sm-8">
                                        <input id="introduction" name="introduction" maxlength="500" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.introduction}">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品类型：</label>
                                    <div class="col-sm-8">
                                        <select id="goods_type" name="goods_type" class="form-control">
                                            <!--<option value="1" {if condition="$GoodsInfo.goods_type eq 1"}selected{/if}>普通商品</option>-->
                                            <!--<option value="2" {if condition="$GoodsInfo.goods_type eq 2"}selected{/if}>升级商品</option>-->
                                            <option value="1" {if condition="$GoodsInfo.goods_type eq 1"}selected{/if}>积分商品</option>

                                            <option value="2" {if condition="$GoodsInfo.goods_type eq 2"}selected{/if}>礼包商品</option>
                                            <option value="3" {if condition="$GoodsInfo.goods_type eq 3"}selected{/if}>复购商品</option>
                                            <option value="4" {if condition="$GoodsInfo.goods_type eq 4"}selected{/if}>秒杀商品</option>
                                            <option value="5" {if condition="$GoodsInfo.goods_type eq 5"}selected{/if}>拼团商品</option>
                                        </select>
                                    </div>
                                </div>
<!--拼团   -->
 <div id="pin" {if condition="$GoodsInfo.goods_type neq 5"}style="display:none"{/if}>
    <div class="form-group">
        <label class="col-sm-3 control-label">拼团券：</label>
        <div class="col-sm-8">
            <div class="input-group">
                <input id="quan" name="quan" type="text" class="form-control"  aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''"  value="{$GoodsInfo.quan}">
                <div class="input-group-addon">元</div>
            </div>
        </div>
    </div> 
    <div class="form-group">
        <label class="col-sm-3 control-label">拼团人数：</label>
        <div class="col-sm-8">
            <div class="input-group">
                <input id="allpeople" name="allpeople" type="text" class="form-control"  aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''"  value="{$GoodsInfo.allpeople}">
                <div class="input-group-addon">人</div>
            </div>
        </div>
    </div> 
    <div class="form-group">
        <label class="col-sm-3 control-label">拼到人数：</label>
        <div class="col-sm-8">
            <div class="input-group">
                <input id="getpeople" name="getpeople" type="text" class="form-control"  aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''"  value="{$GoodsInfo.getpeople}">
                <div class="input-group-addon">人</div>
            </div>
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label">返还红包：</label>
        <div class="col-sm-8">
            <div class="input-group">
                <input id="backred" name="backred" type="text" class="form-control"  aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''"  value="{$GoodsInfo.backred}">
                <div class="input-group-addon">元</div>
            </div>
        </div>
    </div>
</div>
 <div id="miao" {if condition="$GoodsInfo.goods_type neq 4"}style="display:none"{/if}>
    <div class="form-group">
        <label class="col-sm-3 control-label">开始时间：</label>
        <div class="col-sm-8">
            <input id="btime" name="btime" maxlength="500" type="datetime-local" class="form-control" aria-required="true" >
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label">结束时间：</label>
        <div class="col-sm-8">
            <input id="etime" name="etime" maxlength="500" type="datetime-local" class="form-control" aria-required="true" >
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label">库存：</label>
        <div class="col-sm-8">
            <input id="mnum" name="mnum" maxlength="500" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.mnum}">
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label">限购数量：</label>
        <div class="col-sm-8">
            <input id="xiangou" name="xiangou" maxlength="500" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.xiangou}">
        </div>
    </div>
</div>                               
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品分类：</label>
                                    <div class="col-sm-4">
                                        <select id="parent_id" class="form-control">
                                            <option value="0">选择父级分类</option>
                                            {volist name="ClassList" id="v"}
                                            <option value="{$v.id}" {if condition="$GoodsInfo.parent_id eq $v.id"}selected{/if}>{$v.name}</option>
                                            {/volist}
                                        </select>
                                    </div>
                                    <div class="col-sm-4">
                                        <select id="son_id" class="form-control">
                                            <option value="0">选择子级分类</option>
                                            {volist name="ClassSon" id="vv"}
                                            <option value="{$vv.id}" {if condition="$GoodsInfo.son_id eq $vv.id"}selected{/if}>{$vv.name}</option>
                                            {/volist}
                                        </select>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">销售价：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="price" name="price" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.price}" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
 <div id="jin" {if condition="$GoodsInfo.goods_type neq 3"}style="display:none"{/if}>                                
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">VIP：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="hyprice" name="hyprice" value="{$GoodsInfo.hyprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">代理价：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="dlprice" name="dlprice" value="{$GoodsInfo.dlprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">加盟店：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="dpprice" name="dpprice" value="{$GoodsInfo.dpprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">区县加盟商：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="qxprice" name="qxprice" value="{$GoodsInfo.qxprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">市级加盟商：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="sjprice" name="sjprice" value="{$GoodsInfo.sjprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">省级加盟商：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="shprice" name="shprice" value="{$GoodsInfo.shprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                        <div class="form-group">
                            <label class="col-sm-3 control-label">合伙人价：</label>
                            <div class="col-sm-8">
                                <div class="input-group">
                                    <input id="hhrprice" name="hhrprice" value="{$GoodsInfo.hhrprice}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                    <div class="input-group-addon">元</div>
                                </div>
                            </div>
                        </div>
</div>                                

                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品单位：</label>
                                    <div class="col-sm-8">
                                        <input id="unit" name="unit" maxlength="50" type="text" class="form-control" placeholder="件" required="" aria-required="true" value="{$GoodsInfo.unit}">
                                    </div>
                                </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">升级：</label>
                        <div class="col-sm-8">
                            <select id="is_sheng" name="is_sheng" class="form-control">
                                <option value="0"{if condition="$GoodsInfo.is_sheng eq 0"}selected{/if}>不升级</option>
                                <option value="1"{if condition="$GoodsInfo.is_sheng eq 1"}selected{/if}>VIP</option>
                                <option value="2"{if condition="$GoodsInfo.is_sheng eq 2"}selected{/if}>代理</option>
                            </select>
                        </div>
                    </div>
                            <div class="form-group" style="display:none;">
                                <label class="col-sm-3 control-label">直推积分：</label>
                                <div class="col-sm-8">
                                    <div class="input-group">
                                        <input id="reward_1" name="reward_1" type="text" class="form-control"
                                               required="" aria-required="true" value="{$GoodsInfo.reward_1}"
                                               onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''">
                                        <div class="input-group-addon">元</div>
                                    </div>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-sm-3 control-label">直推余额：</label>
                                <div class="col-sm-8">
                                    <div class="input-group">
                                        <input id="zhiyu" name="zhiyu" type="text" class="form-control"
                                               required="" aria-required="true" value="{$GoodsInfo.zhiyu}"
                                               onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''">
                                        <div class="input-group-addon">元</div>
                                    </div>
                                </div>
                            </div>
                            <div class="form-group" style="display: none">
                                    <label class="col-sm-3 control-label">店铺奖励：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="dian" name="dian" value="{$GoodsInfo.dian}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">VIP级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="oneji" name="oneji" type="text" value="{$GoodsInfo.oneji}" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">VIP平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="onep" name="onep" value="{$GoodsInfo.onep}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">代理级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="twoji" name="twoji" value="{$GoodsInfo.twoji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">代理平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="twop" name="twop" value="{$GoodsInfo.twop}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">加盟店级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="threeji" name="threeji" value="{$GoodsInfo.threeji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">加盟店平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="threep" name="threep" value="{$GoodsInfo.threep}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">区县加盟商级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="fourji" name="fourji" value="{$GoodsInfo.fourji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">区县加盟商平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="fourp" name="fourp" value="{$GoodsInfo.fourp}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">市级加盟商级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="fiveji" name="fiveji" value="{$GoodsInfo.fiveji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">市级加盟商平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="fivep" name="fivep" value="{$GoodsInfo.fivep}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">省级加盟商级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="sixji" name="sixji" value="{$GoodsInfo.sixji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">省级加盟商平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="sixp" name="sixp" value="{$GoodsInfo.sixp}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">合伙人级差：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="sevenji" name="sevenji" value="{$GoodsInfo.sevenji}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>
                    <div class="form-group" style="display: none">
                        <label class="col-sm-3 control-label">合伙人平级：</label>
                        <div class="col-sm-8">
                            <div class="input-group">
                                <input id="sevenp" name="sevenp" value="{$GoodsInfo.sevenp}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                <div class="input-group-addon">元</div>
                            </div>
                        </div>
                    </div>




                                <div class="form-group">
                                    <label class="col-sm-3 control-label">落地奖区县代级差：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="xian" name="xian" value="{$GoodsInfo.xian}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">落地奖市代级差：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="shi" name="shi" type="text" value="{$GoodsInfo.shi}" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">落地奖省代级差：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="sheng" name="sheng" value="{$GoodsInfo.sheng}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">是否包邮：</label>
                                    <div class="col-sm-8">
                                        <select id="is_bao" class="form-control">
                                            <option value="1" {if condition="$GoodsInfo.is_bao eq 1"}selected{/if}>是</option>
                                            <option value="2" {if condition="$GoodsInfo.is_bao eq 2"}selected{/if}>否</option>
                                        </select>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">是否上架：</label>
                                    <div class="col-sm-8">
                                        <select id="is_shelf" class="form-control">
                                            <option value="1" {if condition="$GoodsInfo.is_shelf eq 1"}selected{/if}>下架</option>
                                            <option value="2" {if condition="$GoodsInfo.is_shelf eq 2"}selected{/if}>上架</option>
                                        </select>
                                    </div>
                                </div>

                                <div class="form-group">
                                    <label class="col-sm-3 control-label">是否推荐：</label>
                                    <div class="col-sm-8">
                                        <select id="is_recommend" class="form-control">
                                            <option value="1" {if condition="$GoodsInfo.is_recommend eq 1"}selected{/if}>否</option>
                                            <option value="2" {if condition="$GoodsInfo.is_recommend eq 2"}selected{/if}>是</option>
                                        </select>
                                    </div>
                                </div>
                                
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品顺序：</label>
                                    <div class="col-sm-8">
                                        <input id="xu" name="xu" maxlength="255" type="text" class="form-control" required="" aria-required="true" value="{$GoodsInfo.xu}">
                                    </div>
                                </div>
                                
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">北京：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d1" name="d1" value="{$GoodsInfo.d1}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">上海：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d2" name="d2" value="{$GoodsInfo.d2}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">天津：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d3" name="d3" value="{$GoodsInfo.d3}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">重庆：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d4" name="d4" value="{$GoodsInfo.d4}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">河北：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d5" name="d5" value="{$GoodsInfo.d5}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">山西：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d6" name="d6" value="{$GoodsInfo.d6}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">河南：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d7" name="d7" value="{$GoodsInfo.d7}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">辽宁：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d8" name="d8" value="{$GoodsInfo.d8}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">吉林：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d9" name="d9" value="{$GoodsInfo.d9}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">黑龙江：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d10" name="d10" value="{$GoodsInfo.d10}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">内蒙古：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d11" name="d11" value="{$GoodsInfo.d11}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">江苏：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d12" name="d12" value="{$GoodsInfo.d12}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">山东：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d13" name="d13" value="{$GoodsInfo.d13}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">安徽：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d14" name="d14" value="{$GoodsInfo.d14}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">浙江：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d15" name="d15" value="{$GoodsInfo.d15}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">福建：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d16" name="d16" value="{$GoodsInfo.d16}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">湖北：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d17" name="d17" value="{$GoodsInfo.d17}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">湖南：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d18" name="d18" value="{$GoodsInfo.d18}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">广东：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d19" name="d19" value="{$GoodsInfo.d19}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">广西：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d20" name="d20" value="{$GoodsInfo.d20}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">江西：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d21" name="d21" value="{$GoodsInfo.d21}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">四川：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d22" name="d22" value="{$GoodsInfo.d22}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">海南：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d23" name="d23" value="{$GoodsInfo.d23}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">贵州：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d24" name="d24" value="{$GoodsInfo.d24}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">云南：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d25" name="d25" value="{$GoodsInfo.d25}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">西藏：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d26" name="d26" value="{$GoodsInfo.d26}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">陕西：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d27" name="d27" value="{$GoodsInfo.d27}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">甘肃：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d28" name="d28" value="{$GoodsInfo.d28}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">青海：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d29" name="d29" value="{$GoodsInfo.d29}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">宁夏：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d30" name="d30" value="{$GoodsInfo.d30}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">新疆：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d31" name="d31" value="{$GoodsInfo.d31}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">台湾：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d32" name="d32" value="{$GoodsInfo.d32}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">钓鱼岛：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d33" name="d33" value="{$GoodsInfo.d33}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-sm-3 control-label">港澳：</label>
                                    <div class="col-sm-8">
                                        <div class="input-group">
                                            <input id="d34" name="d34" value="{$GoodsInfo.d34}" type="text" class="form-control" required="" aria-required="true" onkeyup="this.value= this.value.match(/\d+(\.\d{0,2})?/) ? this.value.match(/\d+(\.\d{0,2})?/)[0] : ''" >
                                            <div class="input-group-addon">元</div>
                                        </div>
                                    </div>
                                </div>
                                
                                

                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品Logo：</label>
                                    <div class="col-sm-8">
                                        <label for="logo_url">
                                            <img id="m_logo_url" src="{$GoodsInfo.logo_url}" style="max-width:  100%">
                                            <input type="file" id="logo_url" class="upload_pic" style="display: none;">
                                        </label>
                                        <span class="help-block m-b-none"><i class="fa fa-info-circle"></i> Logo尺寸：80*80</span>
                                    </div>
                                </div>

                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品相册：</label>
                                    <div class="col-sm-8">
                                        <label for="album_1">
                                            <img id="m_album_1" src="{$GoodsInfo.album_1}" onerror="this.src='/static/Admin/img/no_img.png'" style="max-width:  100%">
                                            <input type="file" id="album_1" class="upload_pic" style="display: none;">
                                        </label>
                                    </div>
                                </div>

                                <div class="form-group">
                                    <label class="col-sm-3 control-label"></label>
                                    <div class="col-sm-8">
                                        <label for="album_2">
                                            <img id="m_album_2" src="{$GoodsInfo.album_2}" onerror="this.src='/static/Admin/img/no_img.png'" style="max-width:  100%">
                                            <input type="file" id="album_2" class="upload_pic" style="display: none;">
                                        </label>
                                    </div>
                                </div>

                                <div class="form-group">
                                    <label class="col-sm-3 control-label"></label>
                                    <div class="col-sm-8">
                                        <label for="album_3">
                                            <img id="m_album_3" src="{$GoodsInfo.album_3}" onerror="this.src='/static/Admin/img/no_img.png'" style="max-width:  100%">
                                            <input type="file" id="album_3" class="upload_pic" style="display: none;">
                                        </label>
                                        <span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 相册尺寸：375*375</span>
                                    </div>
                                </div>

                                <div class="form-group">
                                    <label class="col-sm-3 control-label">商品详情：</label>
                                    <div class="col-sm-8">
                                        <script id="detail" type="text/plain" style="width:100%;height:400px;">{$GoodsInfo.detail}</script>
                                    </div>
                                </div>
                                <input type="hidden" id="id" value="{$GoodsInfo.id}">
                                <div class="form-group">
                                    <div class="col-sm-4 col-sm-offset-3">
                                        <button class="btn btn-primary" type="button" id="sub">保存并修改</button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>


</div>
{include file="public/footer"}
<script type="text/javascript" src="__STATIC__/Admin/ueditor/1.4.3/ueditor.config.js"></script>
<script type="text/javascript" src="__STATIC__/Admin/ueditor/1.4.3/ueditor.all.min.js"> </script>
<script type="text/javascript" src="__STATIC__/Admin/ueditor/1.4.3/lang/zh-cn/zh-cn.js"></script>

<!--秒杀商品显示开始时间-->
<script>
    $(function() {
        $("#goods_type").change(function(){
            val = $(this).val();
            //秒杀
            if(val == 4){
                $("#miao").css('display','block'); 
            }else{
                $("#miao").css('display','none'); 
            }
            //复购
            if(val == 3){
                $("#jin").css('display','block'); 
            }else{
                $("#jin").css('display','none'); 
            }
            //拼团
            if(val == 5){
                $("#pin").css('display','block'); 
            }else{
                $("#pin").css('display','none'); 
            }
        });
    });
</script>

<script>
    var editor = new UE.ui.Editor();
    editor.render("detail");

    var goods_type = $('#goods_type').val();
    // 报单
    // if(goods_type == 2){
    //     $('.goods_level').show();
    //     $('.grant').show();
    // }else{
    //     $('.goods_level').hide();
    //     $('.grant').hide();
    // }

    // $('#goods_type').change(function () {
    //     var goods_type = $(this).val();
    //     if(goods_type == 2){
    //         $('.goods_level').show();
    //         $('.grant').show();
    //     }else{
    //         $('.goods_level').hide();
    //         $('.grant').hide();
    //     }
    // })

    $('#parent_id').change(function(){
        $("#son_id").html('<option>选择子级分类</option>');
        $.ajax({
            type:"post",
            url:"{:url('Goods/SonChoose')}",
            data:'parent_id='+$('#parent_id').val(),
            dataType:"json",
            success:function(data){
                $('#son_id').show();
                $('#son_id').html(data);
            }
        });
    });

    //ajax异步图片上传
    $('.upload_pic').change(function(){
        //图片对象
        let that = $(this);
        var formData = new FormData();
        formData.append("image", that[0].files[0]);

        // 上传设置
        $.ajax({
            // 规定把请求发送到那个URL
            url: "{:url('Goods/forUpload')}",
            type: "post",            // 请求方式
            dtaType: 'json',
            data: formData,//传值就传fd对象了
            processData:false,  //告诉jQuery不要处理数据
            contentType: false,  //告诉jQuery不要设置contentType
            // 请求成功时执行的回调函数
            success: function (data) {
                if(data.status == 1)
                {
                    that.prev().attr('src',data.message);
                }
                else
                {
                    alert(data.message);
                }
            }
        });
    });

    //保存操作
    $("#sub").on('click',function(){
        var id = $('#id').val();    //商品ID
        var name = $('#name').val();    //商品名称
        var introduction = $('#introduction').val();    //商品简介
        var goods_type = $('#goods_type').val();    //商品类型
        // var goods_level = $('#goods_level').val();    //商品对应等级
        var parent_id = $('#parent_id').val();  //父级分类
        var son_id = $('#son_id').val();    //子级分类
        var price = $('#price').val();    //市场价
        var hyprice = $('#hyprice').val();    //会员价
        var unit = $('#unit').val();    //商品单位
        var reward_1 = $('#reward_1').val();    //一代奖励
        var is_bao = $('#is_bao').val();    //是否包邮
        var dian = $('#dian').val();    //县代
        var dpprice = $('#dpprice').val();    
        var qxprice = $('#qxprice').val();    
        var sjprice = $('#sjprice').val();    
        var shprice = $('#shprice').val();
        var dlprice = $('#dlprice').val();
        var hhrprice = $('#hhrprice').val();
        var oneji = $('#oneji').val();
        var onep = $('#onep').val();
        var twoji = $('#twoji').val();
        var twop = $('#twop').val();
        var threeji = $('#threeji').val();
        var threep = $('#threep').val();
        var fourji = $('#fourji').val();
        var fourp = $('#fourp').val();
        var fiveji = $('#fiveji').val();
        var fivep = $('#fivep').val();
        var sixji = $('#sixji').val();
        var sixp = $('#sixp').val();
        var sevenji = $('#sevenji').val();
        var sevenp = $('#sevenp').val();
        var is_sheng = $('#is_sheng').val();

        var xian = $('#xian').val();    //县代
        var shi = $('#shi').val();    //市代
        var sheng = $('#sheng').val();    //省代
        var is_shelf = $('#is_shelf').val();    //是否上架
        var is_recommend = $('#is_recommend').val();    //是否推荐
        var logo_url = $('#m_logo_url').attr('src');  //Logo
        var album_1 = $('#m_album_1').attr('src');  //相册1
        var album_2 = $('#m_album_2').attr('src');  //相册2
        var album_3 = $('#m_album_3').attr('src');  //相册3
        var detail = editor.getContent();
        var btime = $('#btime').val();  
        var etime = $('#etime').val();  
        var mnum = $('#mnum').val(); 
        var quan = $('#quan').val(); 
        var allpeople = $('#allpeople').val(); 
        var getpeople = $('#getpeople').val(); 
        var backred = $('#backred').val();
        var zhiyu = $('#zhiyu').val();
        var xiangou = $('#xiangou').val(); 
        var d1 = $('#d1').val(); 
        var d2 = $('#d2').val(); 
        var d3 = $('#d3').val(); 
        var d4 = $('#d4').val(); 
        var d5 = $('#d5').val(); 
        var d6 = $('#d6').val(); 
        var d7 = $('#d7').val(); 
        var d8 = $('#d8').val(); 
        var d9 = $('#d9').val(); 
        var d10 = $('#d10').val(); 
        var d11 = $('#d11').val(); 
        var d12 = $('#d12').val(); 
        var d13 = $('#d13').val(); 
        var d14 = $('#d14').val(); 
        var d15 = $('#d15').val(); 
        var d16 = $('#d16').val(); 
        var d17 = $('#d17').val(); 
        var d18 = $('#d18').val(); 
        var d19 = $('#d19').val(); 
        var d20 = $('#d20').val(); 
        var d21 = $('#d21').val(); 
        var d22 = $('#d22').val(); 
        var d23 = $('#d23').val(); 
        var d24 = $('#d24').val(); 
        var d25 = $('#d25').val(); 
        var d26 = $('#d26').val(); 
        var d27 = $('#d27').val(); 
        var d28 = $('#d28').val(); 
        var d29 = $('#d29').val(); 
        var d30 = $('#d30').val(); 
        var d31 = $('#d31').val(); 
        var d32 = $('#d32').val(); 
        var d33 = $('#d33').val(); 
        var d34 = $('#d34').val(); 
        var xu = $('#xu').val(); 
        if(name == ''){
            layer.msg('请输入商品名称',{icon: 5,time:2000});
            return false;
        }

        if(introduction == ''){
            layer.msg('请输入商品简介',{icon: 5,time:2000});
            return false;
        }

        

        if(parent_id == 0){
            layer.msg('请选择父级分类',{icon: 5,time:2000});
            return false;
        }

        if(unit == ''){
            layer.msg('请输入商品单位',{icon: 5,time:2000});
            return false;
        }

        if(logo_url == '/static/Admin/img/no_img.png'){
            layer.msg('请上传商品Logo',{icon: 5,time:2000});
            return false;
        }

        if(album_1 == '/static/Admin/img/no_img.png' && album_2 == '/static/Admin/img/no_img.png' && album_3 == '/static/Admin/img/no_img.png'){
            layer.msg('请至少上传一张商品相册图片',{icon: 5,time:2000});
            return false;
        }

        if(album_1 == '/static/Admin/img/no_img.png'){
            var album_1 = '';
        }

        if(album_2 == '/static/Admin/img/no_img.png'){
            var album_2 = '';
        }

        if(album_3 == '/static/Admin/img/no_img.png'){
            var album_3 = '';
        }

        if(detail == ''){
            layer.msg('请添加商品详情',{icon: 5,time:2000});
            return false;
        }



        $.ajax({
            type:"POST",
            url:"{:url('Goods/GoodsEdit')}",
            data:{
                id:id,
                name:name,
                introduction:introduction,
                goods_type:goods_type,
                parent_id:parent_id,
                son_id:son_id,
                price:price,
                hyprice:hyprice,
                unit:unit,
                reward_1:reward_1,
                dpprice:dpprice,
                qxprice:qxprice,
                sjprice:sjprice,
                shprice:shprice,
                dlprice:dlprice,
                hhrprice:hhrprice,
                oneji:oneji,
                onep:onep,
                twoji:twoji,
                twop:twop,
                threeji:threeji,
                threep:threep,
                fourji:fourji,
                fourp:fourp,
                fiveji:fiveji,
                fivep:fivep,
                sixji:sixji,
                sixp:sixp,
                sevenji:sevenji,
                sevenp:sevenp,
                is_sheng:is_sheng,

                dian:dian,
                is_bao:is_bao,
                xian:xian,
                shi:shi,
                sheng:sheng,
                is_shelf:is_shelf,
                is_recommend:is_recommend,
                logo_url:logo_url,
                album_1:album_1,
                album_2:album_2,
                album_3:album_3,
                detail:detail,
                btime:btime,
                etime:etime,
                mnum:mnum,
                 quan:quan,
                allpeople:allpeople,
                getpeople:getpeople,
                backred:backred,
                zhiyu:zhiyu,
                xiangou:xiangou,
                d1:d1,
                d2:d2,
                d3:d3,
                d4:d4,
                d5:d5,
                d6:d6,
                d7:d7,
                d8:d8,
                d9:d9,
                d10:d10,
                d11:d11,
                d12:d12,
                d13:d13,
                d14:d14,
                d15:d15,
                d16:d16,
                d17:d17,
                d18:d18,
                d19:d19,
                d20:d20,
                d21:d21,
                d22:d22,
                d23:d23,
                d24:d24,
                d25:d25,
                d26:d26,
                d27:d27,
                d28:d28,
                d29:d29,
                d30:d30,
                d31:d31,
                d32:d32,
                d33:d33,
                d34:d34,
                xu:xu,
            },
            dataType:"json",
            success:function(data){
                if(data.status == 1){
                    layer.msg(data.message, {icon: 6,time:2000},function () {
                        window.top.location.reload();
                    });
                }else{
                    layer.msg(data.message,{icon: 5,time:2000});
                }
            }
        });
    })
</script>
</body>

</html>
